package cn.findviewbydream.evil.app.dao;

import cn.findviewbydream.evil.main.entity.*;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/********************************************
 * 工程名：MealOrder
 * 包名：cn.findviewbydream.evil.app.dao
 * 时间：16-12-28
 * 作者：白雨濃 evil
 * 邮箱：evilbai@foxmail.com
 * 内容：
 ********************************************/
@Repository
public interface MenuDAO
{
    List<MealEntity> selectMealList();

    List<BaseMealTypeEntity> selectBaseMealTypeList();

    BaseMealTypeEntity selectMealTypeById(int id);

    BaseTypeOfWorkEntity selectTypeOfWorkById(int id);

    /*插入订单*/
    int insertOrder(OrderEntity entity);

    /*插入订单项目*/
    int insertOrderItem(OrderItemEntity entity);

    /*插入订单与订单项目关联表*/
    int insertLinkOrderOrderItem(@Param("orderId") int orderId, @Param("orderItemId") int orderItemId);

    /*更新老的订单*/
    int updateOrder(OrderEntity entity);

}
